package com.gzhu.knowledgeAdmin.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.gzhu.knowledgeAdmin.common.vo.*;
import com.gzhu.knowledgeAdmin.entity.Zs;
import org.springframework.web.multipart.MultipartFile;

import java.io.IOException;
import java.util.List;
import java.util.Map;

/**
 * 知识表
 *
 * @author giaogiao
 * @email giaogiao@gmail.com
 * @date 2023-04-22 23:18:59
 */
public interface ZsService extends IService<Zs> {

    PageVo queryPage(Map<String, Object> params);

    // 知识生效
    void effective(List<Integer> ids);

    // 添加知识
    void saveZs(KnowledgeAddOrUpdateVo zs);

    void removeZsByIds(List<Integer> ids);

    List<OneLevel> getAllOneLevel();



    KnowledgeResponseVo getZsById(Integer id);

    KnowledgeDetailVo getZsDetail(Integer id);

    void cacheZsByGsId(String gsId);

    List<String> getAnswerByQuestion(KnowledgeQueryVo queryVo);

    void notPass(NotPassVo notPassVo);

    KnowledgeFailDetailVo getZsFailDetail(Integer id);

    PageVo queryMyKnowledgePage(Map<String, Object> params);

    void updateAndReEamine(KnowledgeAddOrUpdateVo knowledgeAddOrUpdateVo);

    PageVo search(Map<String, Object> params);

    void importAllToES() throws InterruptedException;

    void updateZs(KnowledgeAddOrUpdateVo knowledgeAddOrUpdateVo);

    String importZS(MultipartFile file) throws IOException;
}

